package com.yingyi.exception;

import com.yingyi.enums.ExceptionEnums;
import lombok.Getter;

@Getter
public class CustomizedException extends RuntimeException {
    private String message;

    private String code;


    public CustomizedException() {
    }

    public CustomizedException(String message, String code) {
        super(message);
        this.message = message;
        this.code = code;
    }


    public CustomizedException(ExceptionEnums ee) {
        super(ee.getMessage());

        this.message = ee.getMessage();
        this.code = ee.getCode();
    }


}
